Method and apparatus for encrypting and compressing multimedia data

ABSTRACT

Disclosed herein is a method and apparatus for encrypting and compressing multimedia data, which transforms and compresses multimedia data through an encryption key in a process of compressing the multimedia data to record and transmit the data, and encrypts the multimedia data to allow the data to be decoded using only the encryption key. The method includes creating Discrete Cosine Transform (DCT) coefficients by applying input multimedia data to a DCT unit, and quantizing the DCT coefficients; encrypting and compressing transformed Differential Coefficients (DC coefficient) and transformed Amplitude Coefficients (AC coefficient) by transforming encoded DC and AC coefficients depending on a certain encryption key at the time of entropy encoding quantized DC and AC coefficients of the quantized DCT coefficients; and Huffmann coding the encrypted DC and AC coefficients and outputting the coded DC and AC coefficients. The method is a data compression method suitable for processing multimedia data for wireless communication.

BACKGROUND OF THE INVENTION

[0001] 1. Field of the Invention

[0002] The present invention relates generally to a method and apparatusfor encrypting and compressing multimedia data, and more particularly toa method and apparatus for encrypting and compressing multimedia data,which transforms and compresses multimedia data through a certainencryption key in a process of compressing the multimedia data to recordand transmit the multimedia data, and which encrypts the multimedia datato allow the multimedia data to be decoded using only the encryption keyused in the compressing process. The present application is based onKorean Patent Application No. 2002-72813, which is incorporated hereinby reference.

[0003] 2. Description of the Related Art

[0004] Moving Picture Experts Group (MPEG) standards are internationalstandards for methods of compressing and storing, and transmittingmoving images and audio data, and, methods of decompressing, processingand coding compressed information. The MPEG standards include MPEG-1,MPEG-2 and MPEG-4. Of the MPEG standards, MPEG-1 (ISO/CEI 11172), whichis the most basic method of compressing multimedia data, eliminates ortransforms duplicated information and compresses moving image signals byapplying statistical properties to the remaining or transformedmultimedia data.

[0005] MPEG standards use Discrete Cosine Transform (hereinafterreferred to as “DCT”) and quantization to remove spatial redundancy, useDifferential Pulse Code Modulation (DPCM) to remove temporal redundancy,and additionally use entropy encoding including Run Length Coding (RLC)and Hoffmann coding.

[0006] Additionally, MPEG standards basically include Groups Of Pictures(GOPs) each of which is a set of frames. Each of the GOPs includes anIntra-frame (I-frame), a forward Predicted frame (P-frame) and aBi-directional predicted frame (B-frame).

[0007] Recently, as a wireless communication technology has developedand a mobile communication technology has been widely used, multimediaservices based on the compressing method have been offered, andtherefore the security of data provided through the multimedia serviceshas been further required.

[0008] That is, corresponding services should be provided only to usershaving service use rights. For example, movies are transmitted only tousers having paid certain fees, or image information is transmitted onlyto users having rights by which they participate in secret conferences.

[0009] The Data Encryption Standard (hereinafter referred to as “DES”)adopted as an international standard algorithm in 1997, is generallyused as an encryption algorithm.

[0010] DES is a block encryption algorithm that processes a block unitof plain text using a symmetric key, and is used to transmit andreproduce compressed multimedia data for providing secure multimediaservices.

[0011] U.S. Pat. No. 6,021,199 entitled “Motion picture data encryptingmethod and computer system and motion picture data encoding/decodingapparatus to which encrypting method is applied” discloses a method ofencrypting multimedia data using an MPEG compression method thatselectively encrypts the I-frames of MPEG data through DES, using theproperty of the I-frame to include original image information, thusreducing the amount of data.

[0012] A process of encrypting multimedia data using such an MPEGcompression method is carried out as shown in FIGS. 1 and 2.

[0013] That is, many of the values of an 8×8 block become 0 through DCTand quantization processes, as shown in FIG. 1.

[0014] To efficiently process the frame data described above, the valuesof Differential Coefficients (hereinafter referred to as “DCcoefficients”) and Amplitude Coefficients (hereinafter referred to as“AC coefficients”) are read in a zig-zag order, for example, in theorder of DC, AC1, AC2, . . . , and AC63, compressed through an entropyencoding process (100), and encrypted through the DES encryption process(200).

[0015] Additionally, as shown in FIG. 2, a multimedia data producerreceives a public key sent from multimedia data receivers at step 1, andgenerates a symmetric key needed to decode encrypted multimedia dataprovided through multimedia services, encrypts the generated symmetrickey using the public key sent from the receiver and sends the symmetrickey to the receiver at step 2.

[0016] The producer periodically changes the symmetric key used in theDES and therefore improves the security of data at step 3.

[0017] A method of encrypting MPEG data using the shared symmetric keyaccording to a DES algorithm requires resources for processingencrypting and decoding processes because the encrypting and decodingprocesses are complicated.

[0018] Additionally, since the method cannot improve a data compressionratio of multimedia data, the method is not suitable for real timemultimedia services provided to wireless mobile terminals.

[0019] Accordingly, there have been demands for a multimedia securitysystem that efficiently handles limits of the bandwidth resources of awireless network environment and limits of the computation resources ofa mobile terminal.

SUMMARY OF THE INVENTION

[0020] Accordingly, the present invention has been made keeping in mindthe above problems occurring in the related art, and an object of thepresent invention is to provide a method and apparatus for encryptingand compressing multimedia data, in which entropy encoding is carriedout depending on a certain encryption key at the time of entropyencoding in an MPEG compression process, and multimedia data isencrypted and compressed depending on transformed encoded results.

[0021] Another object of the present invention is to provide a methodand apparatus for encrypting and compressing multimedia data, in which acoding process is performed using certain symmetric keys, thus improvinga data compression ratio.

[0022] The method for encrypting and compressing multimedia dataaccording to the present invention includes the steps of: creating DCTcoefficients by applying input multimedia data to a DCT unit, andquantizing the created DCT coefficients; encrypting and compressing DCand AC coefficients transformed by transforming encoded DC and ACcoefficients depending on a certain encryption key at the time ofentropy encoding quantized DC and AC coefficients of the quantized DCTcoefficients; and Huffmann coding the encrypted DC and AC coefficientsusing a Huffmann table and outputting the coded DC and AC coefficients.

[0023] Additionally, the apparatus for encrypting and compressingmultimedia data according to the present invention includes: a DCT unitfor creating DCT coefficients including AC and DC coefficients by DCTtransforming multimedia data into discrete signals; a quantization unitfor quantizing the created DCT coefficients using a quantization table;and an entropy encryption encoding unit for encrypting quantized AC andDC coefficients by entropy encoding the quantized AC and DC coefficientsusing a certain encryption key.

BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The above and other objects, features and other advantages of thepresent invention will be more clearly understood from the followingdetailed description taken in conjunction with the accompanyingdrawings, in which:

[0025]FIG. 1 is a view showing a schematic construction of aconventional apparatus for encrypting multimedia data through DES usingan MPEG compression method;

[0026]FIG. 2 is a view showing a schematic construction of aconventional system for encrypting multimedia data through the DES usingan MPEG compression method;

[0027]FIG. 3 is a view showing a schematic construction of an apparatusfor encrypting and compressing multimedia data according to the presentinvention;

[0028]FIG. 4 is a flowchart showing a method for encrypting andcompressing multimedia data according to the present invention;

[0029]FIG. 5 is a view showing a schematic construction of a systemincluding the encrypting and compressing apparatus according to thepresent invention;

[0030]FIGS. 6a to 6 c are views showing an original image and encryptedand compressed results thereof according to the present invention; and

[0031]FIGS. 7a to 7 c are views showing another original image andencrypted and compressed results thereof according to the presentinvention.

DESCRIPTION OF THE EXEMPLARY EMBODIMENTS

[0032] Hereinafter, a method and apparatus for encrypting andcompressing multimedia data according to embodiments of the presentinvention will be described in detail with reference to the attacheddrawings.

[0033] A method and apparatus for encrypting and compressing multimediadata is implemented based on an H.261 moving picture compressionalgorithm of MPEG-1. The meanings of terms for explaining compressionprocesses, and hierarchical structures are defined in the H.261 movingpicture compression algorithm of MPEG-1.

[0034] Accordingly, when the method and apparatus for encrypting andcompressing multimedia data are explained, the detailed description ofthe meanings of terms, hierarchical structures and various kinds ofparameters, which may obscure the point of the present invention, willbe omitted.

[0035] Additionally, in the present invention, DC and AC coefficientsare encrypted by different methods through the use of symmetric keys.The DC coefficient is encrypted by a method in which codes are changedaccording to an encryption key, as provided in “An Efficient MPEG VideoEncryption Algorithm” by Shi and Bhargava. The AC coefficient isencrypted by a method additionally performing lossy compression.

[0036] The apparatus for encrypting and compressing multimedia data willbe described in detail with reference to FIG. 3.

[0037] As shown in FIG. 3, the apparatus for encrypting and compressingmultimedia data according to the present invention includes a DCT unit110 that creates DCT coefficients including AC and DC coefficients byDCT transforming input multimedia data into discrete signals, aquantization unit 150 that quantizes the created DCT coefficients usinga quantization table 130, and an entropy encryption encoding unit 170that encrypts quantized AC and DC coefficients by entropy encoding thequantized AC and DC coefficients using a certain encryption key.

[0038] The entropy encryption encoding unit 170 includes a DPCM unit 171that pulse modulates the quantized DC coefficient of the DCTcoefficients, an RLC unit 173 that scans the quantized AC coefficient ofthe DCT coefficients in a zig-zag run manner, an encryption unit 175that encrypts the DC and AC coefficients using a Variable Length Code(VLC) and a Variable Length Integer (VLI) of each of the DC and ACcoefficients obtained by the DPCM unit 171 and the RLC unit 173, and aHuffmann coding unit 179 that Huffmann codes the encrypted DC and ACcoefficients using a Huffmann table 177.

[0039] The method for encrypting and compressing multimedia data usingthe apparatus described above includes the steps of: creating a DCTcoefficient by applying input multimedia data to the DCT unit 110, andquantizing the created DCT coefficients; encrypting and compressing DCand AC coefficients transformed by transforming encoded DC and ACcoefficients depending on a certain encryption key at the time ofentropy encoding quantized DC and AC coefficients of the quantized DCTcoefficients; and Huffmann coding the encrypted DC and AC coefficientsusing the Huffmann table 177 and outputting the coded DC and ACcoefficients.

[0040] The step of encrypting and compressing the DC and AC coefficientsincludes the steps of: differential pulse code modulating on thequantized DC coefficients and performing RLC of the quantized ACcoefficient; determining the encryption key of the AC and DCcoefficients and a random constant r indicating a start bit of theencryption key, using variable length information, which is a VLC and aVLI, of each of the DC and AC coefficients obtained through the DPCM andthe RLC; and encrypting the AC and DC coefficients using the determinedencryption key.

[0041] The step of encrypting the DC coefficient includes the steps of:determining whether a value of an r-th bit is “1” in the determinedencryption key of the DC coefficient; and transforming the DCcoefficient by performing an exclusive logical sum operation between theVLC of the DC coefficient and 11111111 if the determination result is“1”.

[0042] The step of encrypting the AC coefficient includes the steps of:determining whether a value of an r-th bit is “1” in the determinedencryption key of the AC coefficient; right-shifting the VLI of the ACcoefficient if the determination result is “1”; determining the VLC ofthe AC coefficient through the right-shifted VLI using the Huffmanntable; and transforming the AC coefficient using the determined VLC andVLI.

[0043] The encryption key includes two symmetric keys, and the symmetrickeys are VLCs of the AC and DC coefficients, respectively. Accordingly,the DC and AC coefficients are entropy encoded on the basis of the VLCof each of the DC and AC coefficients, and variable encoded results arecompressed to be decoded by only the VLC.

[0044] An embodiment of the method for encrypting and compressingmultimedia data will be described in detail with reference to theattached drawings.

[0045] For example, a vector matrix of (DC, AC1, AC2, . . . , AC63)according to a zig-zag order is shown in the following Table 1. TABLE 13 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 7 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 00 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

[0046] TABLE 2 Range of DIFF(k) value Bit size (m) Huffmann code 0 0 00−1, 1 1 010 −3, −2, 2, 3 2 011 −7, . . . , −4, 4, . . . , 7 3 100 . . .−255, . . . , −128, 128, . . . , 255 8 1111110

[0047] An 8×8 block is zig-zag scanned using the DC and AC coefficients.The DC coefficient is encoded to a VLC indicating a minimum bit size forexpressing the DC coefficient using the Huffmann Table, and a VLIindicating a bit corresponding to the VLC in the DC coefficient.

[0048] According to the embodiment, since the DC coefficient is “3”, theminimum bit size for expressing “3” is determined to be “2” withreference on Table 2 (Huffmann Code for the DC coefficient).

[0049] Accordingly, the VLC of the DC coefficient is 2(011), and the VLIindicating a bit corresponding to “2” of the bit size of the VLC fromthe least significant bit of 011 expressing “3” of the DC coefficientbecomes 11.

[0050] Additionally, an entropy encoded result of the DC coefficientincluding the VLC and the VLI is 01111.

[0051] The AC coefficient is a series of bit stream, in which the numberof repetitions I of “0” and a bit size m for expressing a non-zeronumber is compressed using RLC. According to the present invention, thenumber of repetitions I is “7”, and the bit size m for expressingnon-zero number “7” is “3” with reference to the following Table 3 (ACcoefficient magnitude category for bit size table). TABLE 3 Bit sizeRange of AC value 0 0 1 −1, 1 2 −3, −2, 2, 3 3 −7, . . . , −4, 4, . . ., 7 4 −15, . . . , −8, 8, . . . , 15 . . . 10 −1023, . . . , −512, 512,. . . , 1023

[0052] TABLE 4 Run/Level Bits VLC 7/1  8 11111010 7/2 12 11111111011 7/316 11111111110101110 7/4 16 11111111110101111 7/5 16 111111111101100007/6 16 11111111110110001 7/7 16 11111111110110010 7/8 1611111111110110011 7/9 16 11111111110110100 7/A 16 11111111110110101

[0053] Accordingly, if the VLC corresponding to (7, 3) is determinedusing Table 4 (Typical AC Huffmann Code Table), the VLC of the ACcoefficient is 11111111110101110.

[0054] Since the VLI indicating a bit size of “3” for expressing “7” inthe VLC is 110, an entropy encoded result of the AC coefficientincluding the VLC and the VLI is 11111111110101110110.

[0055] That is, if the VLC and VLI of each of the DC and AC coefficientsare created through the DPCM unit 171 and the RLC unit 173 of theentropy encryption encoding unit 170 according to the processes,encryption and compression processes are carried out using the VLCs andVLIs.

[0056] Encryption and compression processes using the VLC and VLI ofeach of the DC and AC coefficients will be described with reference toFIG. 4.

[0057] As shown in FIG. 4, the VLC and VLI of each of the DC and ACcoefficients are generated by performing DPCM and RLC of the quantizedDC and AC coefficients, respectively, and an encryption key (hereinafterreferred to as “first and second symmetric keys”) and a random constantr indicating the start bit of the first or second symmetric key 2 aredetermined using the generated VLC and VLI of each of the DC and ACcoefficients at step S1. The first and second symmetric keys aredetermined by the VLCs of the DC and AC coefficients, and the key 1 isdefined as the VLC of the DC coefficient and the key 2 is defined as theVLC of the AC coefficient.

[0058] If the first and second symmetric keys and the random constantare determined, it is determined whether a key corresponds to the DCcoefficient at step S2.

[0059] If a key corresponds to the DC coefficient as a result of thedetermination of step S2, it is determined whether the value of a bitcorresponding to the random constant designated in the first symmetrickey is “1” at step S3. If the value of the bit is “1”, an exclusivelogical sum (XOR) operation between the VLI of the DC coefficient and11111111 is performed at step S4.

[0060] An encoded DC coefficient is transformed depending on a value ofthe VLI varied by the XOR operation with 11111111 at step S5.

[0061] That is, if it is assumed that the random constant is “2” andapplied to the embodiment, and a value of a second bit of the VLI is “1”in the DC coefficient, in which the VLC is 011 and the VLI is 11, sothat a result of the XOR operation with 11111111 is 11111100.

[0062] In the XOR operated result, the VLI constructed by extracting abit corresponding to “2” of the bit size of the VLC becomes 00.

[0063] Accordingly, the encoded DC coefficient is transformed to 01100by the variable VLI.

[0064] If a key does not correspond to the DC coefficient as a result ofthe determination of step S2, it is determined whether the value of thebit corresponding to the random constant designated in the secondsymmetric key is “1” at step S6. If the value of the bit is “1”, the VLIof the AC coefficient is right-shifted at step S7.

[0065] An encoded AC coefficient is transformed depending on the valueof the VLI varied by the right-shifting at step S8.

[0066] That is, according to the embodiment, since the second bit of theVLI is “1” in the AC coefficient in which the VLC is 11111111110101110and the VLI is 110, the VLI becomes 011 if the VLI is right-shifted.

[0067] Since the VLI is 3(011) as the result of step S8, “2” of theminimum size bit for expressing “3” can be applied to the ACcoefficient, so that the AC coefficient is transformed from (7, 3) to(7, 2).

[0068] Accordingly, if Table 4 is searched for the VLC corresponding to(7, 2), the VLC is 111111110111, and the VLI constructed by extracting abit corresponding to the bit size of the VLC is 11.

[0069] The encoded AC coefficient transformed by the variable VLI is1111111011111.

[0070] As described above, compressed AC and DC coefficients areencrypted so that they can be decoded through only the first and secondsymmetric keys, which are the encryption key.

[0071] If the first and second symmetric keys are determined through theprocesses and multimedia data is encrypted and compressed, themultimedia data producer receives a public key from the multimedia datareceiver B, and the first and second symmetric keys are encryptedthrough the public key of the multimedia data receiver B and sent to thereceiver, as shown in FIG. 5.

[0072] Multimedia data receivers decode the multimedia data using theirown private keys so that compressed multimedia data provided through themultimedia services can be decoded.

[0073] That is, since the multimedia data is encoded depending on thefirst and second symmetric keys and the random constant r, multimediadata cannot be decoded and reproduced if a user does not know the firstand second symmetric keys, so that security of the multimedia data canbe ensured.

[0074] The multimedia data producer periodically changes the first andsecond symmetric keys and the random constant r to increase security ofthe multimedia data. The random constant r is changed more often thanthe first and second symmetric keys, so that a time T at an interval ofwhich the first and second symmetric keys are changed is longer than atime t at an interval of which the random constant r is changed.

[0075] Additionally, the bit stream of the AC coefficient is reduced anda data compression ratio is improved through the above describedencrypting and compressing processes according to the present invention.In the present invention, the AC coefficient is transformed from (7, 3)to (7, 2) through the above described encoding process using the secondsymmetric key, so that the AC coefficient can be reduced by 5 bits.

[0076] Accordingly, when it is considered that the 8×8 block is a partof a macro block of a slice layer in a frame, a considerable compressioneffect can be expected in a total moving image file.

[0077] Such encrypted and compressed results will be described withreference to FIGS. 6a to 6 c and FIGS. 7a to 7 c. FIGS. 6a and 7 aillustrate original images, and FIGS. 6b and 7 b illustrate encryptedand compressed results of the original images.

[0078] Decoded results of the encrypted and compressed images using thefirst and second symmetric keys according to the present invention areshown in FIGS. 6c and 7 c.

[0079] As shown in FIGS. 6c and 7 c, effective encoded and decodedresults can be obtained through simple operations, such as XOR operationand right-shifting, according to the present invention.

[0080] Additionally, a conventional data compression ratio compared to adata compression ratio according to the encrypted and compressed resultsof the present invention shown in FIGS. 6a to 6 c and 7 a to 7 c arearranged in Table 5.

[0081] From Table 5, it is confirmed that the data compression ratioaccording to the present invention will be remarkably higher than theconventional data compression ratio. TABLE 5 FIGS. 6a to 6c FIGS. 7a to7c Compression Compression ratio Size ratio Size MPEG Standard  81:131231 40:1 174387 (bytes) Present 118:1 21455 52:1 133968 invention

[0082] Table 6 illustrates overhead required to calculate acorresponding frame. In the case of FIGS. 6a to 6 c, 0.05746 seconds isadditionally taken compared to a compression method according to theMPEG standard, so that the overhead of 1.32% is shown. In the case ofFIGS. 7a to 7 c, 0.039373 seconds is additionally taken compared to thecompression method according to the MPEG standard, so that the overheadof 0.88% is shown.

[0083] From the results, it can be appreciated that the generatedoverhead according to the present invention is a negligible small value.TABLE 6 FIGS. 6a to 6c FIGS. 7a to 7c MPEG standard 3.321732 3.564230(second per frame) Present invention 3.378378 3.603603

[0084] As described above, according to the present invention,encrypting and decoding processes are not complicated because inputmultimedia data is encrypted using entropy encoding results varieddepending on a certain encryption key, so that the present invention issuitable for multimedia services for mobile terminals and a datacompression ratio is high, thus being effective in multimedia processingon a wireless communication.

[0085] Although the exemplary embodiments of the present invention havebeen disclosed for illustrative purposes, those skilled in the art willappreciate that various modifications, additions and substitutions arepossible, without departing from the scope and spirit of the inventionas disclosed in the accompanying claims.

What is claimed is:
 1. A method for encrypting and compressingmultimedia data, comprising the steps of: creating Discrete CosineTransform (DCT) coefficients by applying input multimedia data to a DCTunit, and quantizing the created DCT coefficients; encrypting andcompressing a transformed Differential Coefficient (DC coefficient) anda transformed Amplitude Coefficient (AC coefficient) by transformingencoded DC and AC coefficients depending on a certain encryption key atthe time of entropy encoding quantized DC and AC coefficients of thequantized DCT coefficients; and Huffmann coding the encrypted DC and ACcoefficients using a Huffmann table and outputting the coded DC and ACcoefficients.
 2. The method according to claim 1, wherein the step ofencrypting and compressing the DC and AC coefficients comprises thesteps of: performing Differential Pulse Code Modulation (DPCM) of thequantized DC coefficient and Run Length Coding (RLC) of the quantized ACcoefficient; determining the encryption key of the AC and DCcoefficients and a random constant r indicating a start bit of theencryption key, using variable length information including a VariableLength Code (VLC) and a Variable Length Integer (VLI), of each of the DCand AC coefficients obtained through the DPCM and the RLC; andencrypting the AC and DC coefficients using the determined encryptionkey.
 3. The method according to claim 2, wherein the step of encryptingthe AC and DC coefficients comprises the steps of: determining whether avalue of an r-th bit is “1” in the determined encryption key of the DCcoefficient; and transforming the DC coefficient by performing anexclusive logical sum operation between the VLC of the DC coefficientand 11111111 if the determined value is “1”.
 4. The method according toclaim 2, wherein the step of encrypting the AC and DC coefficientscomprises the steps of: determining whether a value of an r-th bit is“1” in the determined encryption key of the AC coefficient;right-shifting the VLI of the AC coefficient if the determined value is“1”; determining the VLC of the AC coefficient through the right-shiftedVLI using the Huffmann table; and transforming the AC coefficient usingthe determined VLC and VLI.
 5. The method according to claim 4, whereinthe encryption key includes first and second symmetric keys, and thesymmetric keys are VLCs of the AC and DC coefficients, respectively. 6.An apparatus for encrypting and compressing multimedia data, comprising:a DCT unit for creating DCT coefficients including AC and DCcoefficients by DCT transforming input multimedia data into discretesignals; a quantization unit for quantizing the created DCT coefficientsusing a quantization table; and an entropy encryption encoding unit forencrypting quantized AC and DC coefficients by entropy encoding thequantized AC and DC coefficients using a certain encryption key.
 7. Theapparatus according to claim 6, wherein the entropy encryption encodingunit comprises: a DPCM unit for pulse modulating the quantized DCcoefficient of the DCT coefficients; an RLC unit for scanning thequantized AC coefficient of the DCT coefficients in a zig-zag runmanner; an encryption unit for encrypting the DC and AC coefficientsusing a VLC and a VLI of each of the DC and AC coefficients obtained bythe DPCM unit and the RLC unit; and a Huffmann coding unit for Huffmanncoding the encrypted DC and AC coefficients using a Huffmann table.